<!doctype HTML public "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- Click to Convert 5.2: Anything to HTML -->
<!-- http://www.clicktoconvert.com -->

<html>
<head>
<title>gravityboxscheduleuserguide - page 144 of 234</title>
<meta http-equiv=content-type content=text/html;charset=iso-8859-1>
<meta name="Generator" content="Click to Convert">

<!--Start of page styles-->
<STYLE TYPE="text/css">
<!--
 /* Foreground Image Styles */

 /* Position Styles */
 .ts144p0{position:absolute;left:106px;top:97px;}
 .ts144p1{position:absolute;left:352px;top:97px;}
 .ts144p3{position:absolute;left:665px;top:97px;}
 .ts144p7{position:absolute;left:106px;top:113px;}
 .ts144p8{position:absolute;left:706px;top:1026px;}
 .ts144p9{position:absolute;left:331px;top:1044px;}
 .ts144p13{position:absolute;left:106px;top:147px;}
 .ts144p15{position:absolute;left:106px;top:165px;}
 .ts144p17{position:absolute;left:106px;top:183px;}
 .ts144p19{position:absolute;left:106px;top:201px;}
 .ts144p21{position:absolute;left:106px;top:220px;}
 .ts144p23{position:absolute;left:106px;top:238px;}
 .ts144p25{position:absolute;left:106px;top:256px;}
 .ts144p27{position:absolute;left:106px;top:274px;}
 .ts144p28{position:absolute;left:106px;top:292px;}
 .ts144p30{position:absolute;left:106px;top:310px;}
 .ts144p31{position:absolute;left:106px;top:329px;}
 .ts144p32{position:absolute;left:106px;top:347px;}
 .ts144p35{position:absolute;left:106px;top:366px;}
 .ts144p38{position:absolute;left:106px;top:384px;}
 .ts144p39{position:absolute;left:106px;top:403px;}
 .ts144p41{position:absolute;left:106px;top:422px;}
 .ts144p42{position:absolute;left:106px;top:440px;}
 .ts144p44{position:absolute;left:106px;top:458px;}
 .ts144p46{position:absolute;left:106px;top:476px;}
 .ts144p48{position:absolute;left:106px;top:494px;}
 .ts144p50{position:absolute;left:106px;top:512px;}
 .ts144p52{position:absolute;left:106px;top:530px;}
 .ts144p53{position:absolute;left:106px;top:548px;}
 .ts144p56{position:absolute;left:106px;top:567px;}
 .ts144p58{position:absolute;left:106px;top:585px;}
 .ts144p60{position:absolute;left:106px;top:603px;}
 .ts144p62{position:absolute;left:106px;top:621px;}
 .ts144p64{position:absolute;left:106px;top:639px;}
 .ts144p66{position:absolute;left:106px;top:657px;}
 .ts144p69{position:absolute;left:106px;top:675px;}
 .ts144p71{position:absolute;left:106px;top:693px;}
 .ts144p73{position:absolute;left:106px;top:712px;}
 .ts144p75{position:absolute;left:106px;top:730px;}
 .ts144p77{position:absolute;left:106px;top:748px;}
 .ts144p79{position:absolute;left:106px;top:766px;}
 .ts144p81{position:absolute;left:106px;top:784px;}
 .ts144p83{position:absolute;left:106px;top:802px;}
 .ts144p86{position:absolute;left:106px;top:820px;}
 .ts144p88{position:absolute;left:106px;top:838px;}
 .ts144p90{position:absolute;left:106px;top:857px;}
 .ts144p92{position:absolute;left:106px;top:875px;}
 .ts144p93{position:absolute;left:106px;top:893px;}
 .ts144p95{position:absolute;left:106px;top:911px;}
 .ts144p97{position:absolute;left:106px;top:929px;}
 .ts144p98{position:absolute;left:106px;top:947px;}
 .ts144p100{position:absolute;left:106px;top:965px;}
 .ts144p101{position:absolute;left:106px;top:983px;}

 /* Font Styles */
 .ft0p144{font-style:normal;font-weight:bold;font-size:13px;font-family:arial,sans-serif;color:#000000;}
 .ft1p144{font-weight:normal;}
 .ft2p144{font-style:normal;font-weight:normal;font-size:13px;font-family:"times new roman","times new roman",times,serif;color:#000000;}
 .ft3p144{font-style:normal;font-weight:normal;font-size:16px;font-family:"times new roman","times new roman",times,serif;color:#000000;}
 .ft4p144{font-style:normal;font-weight:bold;font-size:11px;font-family:arial,sans-serif;color:#000000;}
 .ft5p144{font-style:normal;font-weight:normal;font-size:16px;font-family:"courier new",courier,monospace;color:#000000;}
 .ft6p144{font-family:arial,sans-serif;}
 .ft7p144{font-style:normal;font-weight:normal;font-size:16px;font-family:arial,sans-serif;color:#000000;}

 /* Background Style */
 .styleBackground144{position:absolute;left:97px;top:145px}

 /* Navigation Styles */
 .styleNavBarTop{position:absolute;left:0px;top:2px}
 .nb{position:absolute;left:2px;top:0px}
 .nbs{position:absolute;left:0px;top:0px}
 .nbe{position:absolute;left:836px;top:0px}
 .styleNavBarBot{position:absolute;left:0px;top:1117px}
-->
</STYLE>
<!--End of page styles-->

</head>
<body bgcolor="#ffffff" text="#000000" link="#0000FF" Vlink="#660099">

<table id="pageTable" width="836" STYLE="position: relative; left: auto; top: auto;"><tr><td>
<div class=nbs><img src="./navbarstart.gif" width="2" height="30"></div>
<div class=nb><img src="./navbar.gif" width="836" height="30" alt="Navigation bar"></div>
<div class=nbe><img src="./navbarend.gif" width="2" height="30"></div>
<div class=styleNavBarTop>
<table width="834" height="26" border="0" cellspacing="0">
  <tr align="left">
    <td width="4">&nbsp;</td>
    <td width="25" align="center"><a href="http://www.gravitybox.com" target="_parent"><img src="./home.gif" border="0" alt="Home"></a></td>
    <td width="25" align="center"><a href="#" onClick="window.open('./print.html','Printing','width=300,height=100,toolbar=no,directories=no');return false;"><img src="./print.gif" border="0" alt="Print document"></a></td>
    <td width="10" align="center"><img src="./separator.gif" border="0"></td>
    <td width="18" align="center"><a href="./index1.html"><img src="./start.gif" width="18" height="14" border="0" alt="Start"></a></td>
    <td width="18" align="center"><a href="./index143.html"><img src="./back.gif" width="14" height="14" border="0" alt="Previous page"></a></td>
    <td width="80" valign="middle"><table width="100%" height="16" border="0" cellspacing="1" bgcolor="#ACA899"><tr><td align="center" bgcolor="#ffffff"><font face=verdana,arial,sans-serif><font size="1">&nbsp;144 of 234&nbsp;</font></font></td></tr></table></td>
    <td width="18" align="center"><a href="./index145.html"><img src="./forward.gif" width="14" height="14" border="0" alt="Next page"></a></td>
    <td width="18" align="center"><a href="./index234.html"><img src="./end.gif" width="18" height="14" border="0" alt="End"></a></td>
    <td width="620">&nbsp;</td>
  </tr>
</table>
<p>
</div>
<nobr>
<div class=styleBackground144><img src="./background144.png" width="633" height="910" border="0" alt=""></div>
<div class=ts144p0><span class="ft0p144"> </span></div>
<div class=ts144p1><span class="ft0p144">Gravitybox Schedule Primer<span class="ft1p144"> </span></span></div>
<div class=ts144p3><span class="ft0p144">Page 142&nbsp; </span></div>
<div class=ts144p7><span class="ft2p144"> </span></div>
<div class=ts144p8><span class="ft3p144"> </span></div>
<div class=ts144p9><span class="ft4p144">1998&#45;2004 Gravitybox Software LLC<span class="ft3p144"> </span></span></div>
<div class=ts144p13><span class="ft5p144">&nbsp; 'Every day has these rooms since every day </span></div>
<div class=ts144p15><span class="ft5p144">&nbsp; 'we have the same number of rooms in our office </span></div>
<div class=ts144p17><span class="ft5p144">&nbsp; Call Schedule1.Rooms.Clear </span></div>
<div class=ts144p19><span class="ft5p144">&nbsp; Call Schedule1.Rooms.Add(&#34;Operatory I&#34;) </span></div>
<div class=ts144p21><span class="ft5p144">&nbsp; Call Schedule1.Rooms.Add(&#34;Operatory II&#34;) </span></div>
<div class=ts144p23><span class="ft5p144">&nbsp; Call Schedule1.Rooms.Add(&#34;Exam I&#34;) </span></div>
<div class=ts144p25><span class="ft5p144">&nbsp; Call Schedule1.Rooms.Add(&#34;Exam II&#34;) </span></div>
<div class=ts144p27><span class="ft5p144"> </span></div>
<div class=ts144p28><span class="ft5p144">End Sub<span class="ft6p144"> </span></span></div>
<div class=ts144p30><span class="ft7p144"> </span></div>
<div class=ts144p31><span class="ft7p144">Now that we know the rooms will be added, we need to write a routine to open and save </span></div>
<div class=ts144p32><span class="ft7p144">files. This application will not use any database access. It will use the built&#45;in XML file </span></div>
<div class=ts144p35><span class="ft7p144">routines. The OpenFile and SaveFile routines will load and save schedules to XML files. </span></div>
<div class=ts144p38><span class="ft7p144"> </span></div>
<div class=ts144p39><span class="ft5p144">Public Function OpenFile(ByVal dtDate As Date) As Boolean </span></div>
<div class=ts144p41><span class="ft5p144"> </span></div>
<div class=ts144p42><span class="ft5p144">Dim oXMLParameters As CXMLParameters </span></div>
<div class=ts144p44><span class="ft5p144">Dim sFileName As String </span></div>
<div class=ts144p46><span class="ft5p144">&nbsp;&nbsp; </span></div>
<div class=ts144p48><span class="ft5p144">&nbsp; 'Save this screen's date </span></div>
<div class=ts144p50><span class="ft5p144">&nbsp; MyDate = dtDate </span></div>
<div class=ts144p52><span class="ft5p144"> </span></div>
<div class=ts144p53><span class="ft5p144">&nbsp; 'This will load a schedule from file (if need be) </span></div>
<div class=ts144p56><span class="ft5p144">&nbsp; sFileName = AppPath &#38; GetFileName(Me.MyDate) </span></div>
<div class=ts144p58><span class="ft5p144">&nbsp; If FileExists(sFileName) Then </span></div>
<div class=ts144p60><span class="ft5p144">&nbsp;&nbsp;&nbsp; Set oXMLParameters = New CXMLParameters </span></div>
<div class=ts144p62><span class="ft5p144">&nbsp;&nbsp;&nbsp; oXMLParameters.FileName = sFileName </span></div>
<div class=ts144p64><span class="ft5p144">&nbsp;&nbsp;&nbsp; oXMLParameters.EmployGMT = False </span></div>
<div class=ts144p66><span class="ft5p144">&nbsp;&nbsp;&nbsp; oXMLParameters.PropertyAll = False </span></div>
<div class=ts144p69><span class="ft5p144">&nbsp;&nbsp;&nbsp; Call oXMLParameters.UseAllCollections(False) </span></div>
<div class=ts144p71><span class="ft5p144">&nbsp;&nbsp;&nbsp; oXMLParameters.VerifyOnly = False </span></div>
<div class=ts144p73><span class="ft5p144">&nbsp;&nbsp;&nbsp; Call Schedule1.ScheduleItems.Clear </span></div>
<div class=ts144p75><span class="ft5p144">&nbsp;&nbsp;&nbsp; Call Schedule1.ImportXML(oXMLParameters) </span></div>
<div class=ts144p77><span class="ft5p144">&nbsp; End If </span></div>
<div class=ts144p79><span class="ft5p144">&nbsp;&nbsp; </span></div>
<div class=ts144p81><span class="ft5p144">&nbsp; 'Setup the caption for this screen </span></div>
<div class=ts144p83><span class="ft5p144">&nbsp; Me.Caption = Format(MyDate, &#34;dddd mmm dd, yyyy&#34;) </span></div>
<div class=ts144p86><span class="ft5p144">&nbsp;&nbsp; </span></div>
<div class=ts144p88><span class="ft5p144">&nbsp; 'There is nothing dirty </span></div>
<div class=ts144p90><span class="ft5p144">&nbsp; Changed = False </span></div>
<div class=ts144p92><span class="ft5p144"> </span></div>
<div class=ts144p93><span class="ft5p144">EndSub: </span></div>
<div class=ts144p95><span class="ft5p144">&nbsp; Set oXMLParameters = Nothing </span></div>
<div class=ts144p97><span class="ft5p144"> </span></div>
<div class=ts144p98><span class="ft5p144">End Function </span></div>
<div class=ts144p100><span class="ft5p144"> </span></div>
<div class=ts144p101><span class="ft5p144">Public Sub SaveFile() </span></div>
<div class=styleNavBarBot>
<table width="836" border="0" cellspacing="2">
  <tr></tr>
  <tr>
    <td width="118"><a href="http://www.purepage.com"><img src="./smalllogo.gif" width="118" height="46" border="0" alt="http://www.purepage.com"></a></td>
    <td></td>
  </tr>
</table>
</div>

</td></tr></table>

</body>
</html>
